/* 
 * File:   DefaultHttpEngine.cpp
 * Author: dell
 * 
 * Created on 2012年4月2日, 上午10:36
 */

#include "DefaultHttpEngine.h"

namespace Rapid{
    DefaultHttpEngine::DefaultHttpEngine(ServerConfig* serverConfig):
        serverConfig(serverConfig),servletFactory(serverConfig) {
    }

    DefaultHttpEngine::~DefaultHttpEngine() {
    }

    HttpServletFactory* DefaultHttpEngine::getHttpServletFactory(){
        return &servletFactory;
    }

    HttpHandlerFactory* DefaultHttpEngine::getHttpHandlerFactory(){
        return &handlerFactory;
    } 
    
}

extern "C" Rapid::IHttpEngine* create(Rapid::ServerConfig* serverConfig, const char* params) {
    return new Rapid::DefaultHttpEngine(serverConfig);
}

extern "C" void destroy(Rapid::IHttpEngine* httpEngine, const char* params) {
    delete httpEngine;
}   




